#!/usr/bin/env python
# -*- coding: utf-8 -*-
# @Time    : 2020/6/16 0016 22:22
# @Author  : wzy
# @Site    : 
# @File    : operate_config.py
# @Software: PyCharm
import json
from Util.operate_json import operateJson

def get_cookie_value(cookie_key):
    data = operateJson.read_json("cookie.json")
    return data[cookie_key]

def write_cookie_value(data,key):
    data1 = operateJson.read_json('cookie.json')
    data1[key] = data
    operateJson.write_json_value(data1)
    print("写入cookie成功")

if __name__ == '__main__':
    data = {
        "a2aaa": "2",
        "cak2er":"余小C真的很强"
    }
    write_cookie_value(data,"is_cookie")



